#####################################################
# Oman Flavor Events
#
# scripted by Johan Andersson
#
# id range = 38500-
# 
#####################################################

event = { 
	id = 38500
	random = no
	country = OMA
	
	name = "EVT_38500_NAME" # Voyage of the Sultana
	desc = "EVT_38500_DESC" # 
	style = 0

	date = { year = 1840 } 
	offset = 100

	action_a = {
        	name = "ACTIONNAME38500A"
        	command = { type = prestige value = 3 }
        	command = { type = relation which = USA value = 25 }
	}
}


event = { 
	id = 38501
	random = no
	country = OMA
	
	trigger = {
		owned = { province = 2509 data = OMA }
		not = { exists = ZAN }
	}
	
	name = "EVT_38501_NAME" # Death of Sultan Said
	desc = "EVT_38501_DESC" # 
	style = 0

	date = { year = 1856 } 
	offset = 100

	action_a = {
        	name = "ACTIONNAME38501A"
        	command = { type = independence which = ZAN }
        	command = { type = trigger which = 38502 }
	}
	action_b = {
        	name = "ACTIONNAME38501B"
        	command = { type = revolt where = 2509 }
        	command = { type = revolt where = 2509 }
        	command = { type = revolt where = 2509 }
	}
}

event = { 
	id = 38502
	random = no
	country = OMA
	
	
	name = "EVT_38502_NAME" # Zanzibar is a Satellite
	desc = "EVT_38501_DESC" # 
	style = 0

	date = { year = 1856 } 
	offset = 100

	action_a = {
        	name = "OK"
        	command = { type = make_satellite which = ZAN }
	}
}


event = { 
	id = 38503
	random = no
	country = OMA
	
	name = "GUARAN_OMAZAN" #  The Zanzibar Question
	desc = "GUARAN_OMAZAN_DESC" # 
	style = 0

	date = { year = 1860 } 
	offset = 100
	deathdate = { year = 1863 } 

	action_a = {
        	name = "ACTIONNAME38503A" 
        	command = { type = end_satellite_mastery which = ZAN }
        	command = { type = setflag which = zanzibar_independent value = 5 }
		command = { type = secedestate which = ZAN value = 2510 when = 0 }
		command = { type = secedestate which = ZAN value = 2235 when = 0 }		 	
		command = { type = secedestate which = ZAN value = 2246 when = 0 }		 	
		}
	action_b = {
        	name = "ACTIONNAME38503B"
        	command = { type = war which = ZAN }
	}
	
}

event = { 
	id = 38504
	random = no
	country = ENG
	
	name = "GUARAN_OMAZAN" # The Zanzibar Question
	desc = "GUARAN_OMAZAN_DESC" # 
	style = 0
	trigger = 
	{
		flag = { which = zanzibar_independent value = 1 }
	}

	date = { year = 1860 } 
	offset = 10
	deathdate = { year = 1863 } 

	action_a = {
        	name = "OK"
        	command = { type = guarantee which = OMA }
        	command = { type = guarantee which = ZAN }
	}
}

event = { 
	id = 38505
	random = no
	country = FRA
	
	name = "GUARAN_OMAZAN" # The Zanzibar Question
	desc = "GUARAN_OMAZAN_DESC" # 
	style = 0
	trigger = 
	{
		flag = { which = zanzibar_independent value = 1 }
	}

	date = { year = 1860 } 
	offset = 10
	deathdate = { year = 1863 } 

	action_a = {
        	name = "OK"
        	command = { type = guarantee which = OMA }
        	command = { type = guarantee which = ZAN }
	}
}

event = { 
	id = 38506
	random = no
	country = ZAN
	
	trigger = {
		exists = ENG
		ai = yes
		ai = ENG
		event = 38503
		event = 38504
		uncolonized = 2246 #mombasa
		is_GP = ENG
		NOT = {
			war = { country = ENG country = ZAN }
			}
		}

	name = "AI_EVENT"
	desc = "AI_EVENT"
	style = 0


	date = { year = 1860 } 
	offset = 10
	deathdate = { year = 1863 } 

	action_a = {
        	name = "OK" 
		command = { type = secedestate which = ENG value = 2246 when = 0 }		 	
		}	
}

 

